package com.catsic.zcjc.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

/**
 * 区县
 */
@Entity
@Table(name = "t_district")
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public class District extends BaseAreaEntity implements Serializable {

    /**
	 * 
	 */
	private static final long serialVersionUID = -3415052404191923431L;
	
	/**
     * id
     */
    @Id
    @GeneratedValue
    @Column(name = "id")
    private Long id;
    /**
     * 地区名称
     */
    @Column(name = "name")
    private String name;
    /**
     * 城市
     */
    @ManyToOne
    @JoinColumn(name = "city_id")
    private City city;
    /**
     * 字母
     */
    @Column(name = "letter")
    private String letter;
    /**
     * 全拼音
     */
    @Column(name = "full_letter")
    private String fullLetter;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public City getCity() {
        return city;
    }

    public void setCity(City city) {
        this.city = city;
    }

    public String getLetter() {
        return letter;
    }

    public void setLetter(String letter) {
        this.letter = letter;
    }

    public String getFullLetter() {
        return fullLetter;
    }

    public void setFullLetter(String fullLetter) {
        this.fullLetter = fullLetter;
    }

}
